In the field of combustion engines having solenoid valves, it may be advantageous for an efficient combustion to precisely time the current into a solenoid valve. Fluctuations of the parameters of the combustion engine like temperature, pressure and aging of the components may influence the timing. Therefore, there is a need for an accurate control of solenoid valves.